const routes = [
  {
    path: '/',
    name: 'Layout',
    redirect: "/home",
    component: () => import('@/layout/index.vue'),
    children: [
      {
        path: "/home",
        name: "Home",
        component: () => import('@/views/home/index.vue'),
        meta: {
          icon: "",
          title: "首页",
          isLoginPermission: false, // 是否需要登录权限
          visitRole: [], // 可访问角色
        }
      }
    ]
  },
  {
    path: '/error',
    name: 'Error',
    component: () => import('@/views/404.vue'),
    meta: {
      icon: "",
      title: "错误页面",
      isLoginPermission: false,
      visitRole: [],
    }
  },
  {
    path: '*',
    redirect: '/error',
    meta: {
      isLoginPermission: false,
    }
  },
]


export default routes